package com.dp.vo;

import java.io.Serializable;
import java.util.Date;

import javax.persistence.Basic;
import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.GeneratedValue;
import javax.persistence.GenerationType;
import javax.persistence.Id;
import javax.persistence.NamedQueries;
import javax.persistence.NamedQuery;
import javax.persistence.Table;
import javax.persistence.Temporal;
import javax.persistence.TemporalType;

import org.apache.struts2.json.annotations.JSON;

@Entity
@Table(name = "news_blacklist")
//@NamedQueries({@NamedQuery(name = "NewsBlacklist.findAll", query = "SELECT n FROM NewsBlacklist n"), @NamedQuery(name = "NewsBlacklist.findById", query = "SELECT n FROM NewsBlacklist n WHERE n.id = :id")})
public class NewsBlacklist implements Serializable {
	    private static final long serialVersionUID = 1L;
	    @Id
	    @GeneratedValue(strategy = GenerationType.IDENTITY)
	    @Basic(optional = false)
	    @Column(name = "id")
	    private String id;
	    @Column(name = "clientid")             
	    private String clientid;                //终端id
	    @Column(name = "name")                
	    private String name;                    //昵称
	    @Column(name = "email")
	    private String email;                   //邮件地址
	    @Column(name = "mobile")
	    private String mobile;                  //手机号码
	    @Column(name = "lastupdatetime")                             
		@Temporal(TemporalType.TIMESTAMP)
		private Date lastupdatetime;   
	    @Column(name = "userid")
	    private String userid;                  //创建人
	    @Column(name = "issystem")
	    private String issystem;                //系统消息黑名单
	    @Column(name = "isup")
	    private String isup;                    //上行黑名单
	    @Column(name = "isdown")
	    private String isdown;                  //共享下行黑名单
	    public NewsBlacklist(){
	    	
	    }
	    public NewsBlacklist(String id){
	    	this.id=id;
	    }
	    
		public String getId() {
			return id;
		}
		public void setId(String id) {
			this.id = id;
		}
		public String getClientid() {
			return clientid;
		}
		public void setClientid(String clientid) {
			this.clientid = clientid;
		}
		public String getName() {
			return name;
		}
		public void setName(String name) {
			this.name = name;
		}
		public String getEmail() {
			return email;
		}
		public void setEmail(String email) {
			this.email = email;
		}
		public String getMobile() {
			return mobile;
		}
		public void setMobile(String mobile) {
			this.mobile = mobile;
		}
		@JSON(format="yyyy-MM-dd HH:mm:ss")
		public Date getLastupdatetime() {
			return lastupdatetime;
		}
		public void setLastupdatetime(Date lastupdatetime) {
			this.lastupdatetime = lastupdatetime;
		}
		public String getUserid() {
			return userid;
		}
		public void setUserid(String userid) {
			this.userid = userid;
		}
		public String getIssystem() {
			return issystem;
		}
		public void setIssystem(String issystem) {
			this.issystem = issystem;
		}
		public String getIsup() {
			return isup;
		}
		public void setIsup(String isup) {
			this.isup = isup;
		}
		public String getIsdown() {
			return isdown;
		}
		public void setIsdown(String isdown) {
			this.isdown = isdown;
		}
		@Override
	    public int hashCode() {
	        int hash = 0;
	        hash += (id != null ? id.hashCode() : 0);
	        return hash;
	    }

	    @Override
	    public boolean equals(Object object) {
	        if (!(object instanceof NewsBlacklist)) {
	            return false;
	        }
	        NewsBlacklist other = (NewsBlacklist) object;
	        if ((this.id == null && other.id != null) || (this.id != null && !this.id.equals(other.id))) {
	            return false;
	        }
	        return true;
	    }

	    @Override
	    public String toString() {
	        return "com.dp.vo.NewsBlacklist[id=" + id + "]";
	    }
}
